POV-Ray : Newsgroups : povray.programming : why is mosaic preview required for radiosity? : Re: why is mosaic preview required for radiosity? Server Time
29 Jul 2024 16:31:08 EDT (-0400)
  Re: why is mosaic preview required for radiosity?  
From: Nieminen Juha
Date: 4 Oct 1999 04:30:33
Message: <37f865a9@news.povray.org>
In povray.advanced-users Peter Popov <peter.popov@usa.net> wrote:
: Several months ago I suggested an alternate way of doing anti-aliasing
: but no one seemed to like it enough to code it :) The idea is to have
: the supersampling pass _after_ the image has been rendered.

  This would mean that you have to keep the entire image in memory?

  Randomizing the order of tracing needs keeping an image-sized buffer
of coordinates in memory anyways. The fastest way to trace in random order
is to have a buffer of coordinates, shuffle them (ie. change the first one
with a random one, then the second one with a random one and so on) and use
them to get the next pixel coordinate to trace.
  Since each coordinate needs at least 2x16 bits (supposing that we don't
want to support images greater than 65536x65536 pixels), for an image
sized, let's say 1024x768 we would need 1024x768x4 bytes = 3 Megabytes.
Since we also have to keep the entire image on memory because we can't
save it in parts, it would require 1024x768x3 bytes = 2.25 Megabytes, ie.
a total of 5.25 Megabytes is required for the process. If we are outputting
to a PNG with 16 bits per color component and alpha channel (ie. 8 bytes
per pixel), things get worse: It would require 1024x768x8 bytes = 6 Megabytes
for the image; the total would then be 9 Megabytes.

  Quite memory consuming, I think. Also accessing 9 Megabytes of memory at
random is slow...

-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):5;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.